package fr.upmc.alasca.centreCalcul.interne.controleurAdmission.ports;

import fr.upmc.alasca.centreCalcul.interne.controleurAdmission.ControleurAdmission;
import fr.upmc.alasca.centreCalcul.interne.controleurAdmission.interfaces.ControleurAdmissionClientI;
import fr.upmc.alasca.centreCalcul.objets.DemandeAdmission;
import fr.upmc.components.ComponentI;
import fr.upmc.components.ports.AbstractOutboundPort;


/**
 * @author Antoine Lavaire, Sabri Labassi, Thibaut Fleury, Ryme Fantazi
 */
public	class	ControleurAdmissionClientOutboundPort
extends			AbstractOutboundPort
implements		ControleurAdmissionClientI
{
	public	ControleurAdmissionClientOutboundPort
	(
		String		p_uri,
		ComponentI	p_owner
	) throws	Exception
	{
		super(p_uri, ControleurAdmissionClientI.class, p_owner);
		
		assert this.uri != null && this.owner instanceof ControleurAdmission;
	}


	@Override
	public	String	soumettreApplication
	(
		DemandeAdmission	p_demandeAdmission
	) throws	Exception
	{
		return ((ControleurAdmissionClientI) this.connector).soumettreApplication(p_demandeAdmission);
	}


	@Override
	public	void	arreterApplication
	(
		String	p_uriApplication
	) throws	Exception
	{
		((ControleurAdmissionClientI) this.connector).arreterApplication(p_uriApplication);
	}
}
